# CMake 最低版本号要求
cmake_minimum_required (VERSION 2.8)

# 项目信息
project (OX_script)

set(DIR_INC       	  ${CMAKE_CURRENT_SOURCE_DIR}/include)
set(DIR_LIB       	  ${CMAKE_CURRENT_SOURCE_DIR}/lib) 
set(DIR_MAIN      	  ${CMAKE_CURRENT_SOURCE_DIR}/src)
set(DIR_CONNECT       ${DIR_MAIN}/connect)
set(DIR_PRINT   	  ${DIR_MAIN}/print)

# 设置头文件和第三方库目录
include_directories(${DIR_INC})
include_directories(${DIR_LIB})
include_directories(${DIR_MAIN})
link_directories(${DIR_LIB})     # 库目录

# 查找当前目录下的所有源文件
# 并将名称保存到 DIR_SRCS 变量
aux_source_directory(${DIR_MAIN}	 				SRCS_MAIN)
aux_source_directory(${DIR_CONNECT}	 				SRCS_CONNECT)
aux_source_directory(${DIR_PRINT}	 				SRCS_PRINT)


# 指定生成目标 
add_library(PSKFUNC SHARED	 			
${SRCS_MAIN}
${SRCS_CONNECT}
${SRCS_PRINT}
)

target_link_libraries(PSKFUNC
nanomsg 
)

set(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bak)


